﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using CoolCode.Entities;

namespace CoolCode.Web.UI.Controls
{
    public partial class ProductSummary : Partial<InspectionSummary>
    {
        protected void Page_Load(object sender, EventArgs e)
        {
        }

        public override void DataBind()
        {
            //base.DataBind();
            if (this.Model == null || this.Model.Count == 0)
            {
                this.Visible = false;
                return;
            }
            rptProduct.DataSource = this.Model;
            rptProduct.DataBind();
        }

        //protected override void Render(HtmlTextWriter writer)
        //{
        //    if (this.Model == null || this.Model.Count == 0)
        //    {
        //        writer.Write("<br/>");
        //        return;
        //    }
        //    base.Render(writer);
        //}
    }
}